import VueRouter from 'vue-router'
import Vue from 'vue'
Vue.use(VueRouter)
import goods from '../views/goods/goods'
import seller from '../views/seller/seller'
import ratings from '../views/ratings/ratings'
const routes = [
  {
    path: '/',
    redirect: '/goods'
  },
  {
    path: '/goods',
    component: goods
  },
  {
    path: '/seller',
    component: seller
  },
  {
    path: '/ratings',
    component: ratings
  }
]
// 3.创建路由对象
const router = new VueRouter({
  routes,
  mode: "history"
})

// 4.导出
export default router